using System;
using System.Data;
using System.Web;
using System.Collections;
using System.Web.Services;
using System.Web.Services.Protocols;
using System.ComponentModel;

using System.Web.Script.Services;
using System.Web.Script.Serialization;

namespace PageControlSample
{
    /// <summary>
    /// Summary description for PageServices
    /// </summary>
    [WebService(Namespace = "http://tempuri.org/")]
    [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
    [ToolboxItem(false)]
    [ScriptService]
    public class PageServices : System.Web.Services.WebService
    {

        [WebMethod]
        public string HelloWorld()
        {
            return "Hello World";
        }

        [WebMethod]
        public string GetResourcesJsonData()
        {
            System.Text.StringBuilder sbJsonData = null;
            JavaScriptSerializer jss = null;

            sbJsonData = new System.Text.StringBuilder();
            jss = new JavaScriptSerializer();

            jss.Serialize(
                Resources.Resources.jp.ResourceManager.GetResourceSet(
                    new System.Globalization.CultureInfo("ja"), true, true), sbJsonData);

            return sbJsonData.ToString();
        }
    }
}
